package net.vanchu.mortgagecalculator.mortgage.data.loan;

/**
 * 商业贷款
 * <p/>
 * Created by Granton on 2016/12/14.
 */
public class ComLoan extends AbsLoan implements WithCommercial {

    private double principal;

    private double rate;

    private double discount;

    public ComLoan(int year, double principal, double rate, double discount) {
        super(year);
        this.principal = principal;
        this.rate = rate;
        this.discount = discount;
    }

    @Override
    public double getCommercialPrincipal() {
        return principal;
    }

    @Override
    public double getCommercialInterestRate() {
        return rate;
    }

    @Override
    public double getCommercialDiscount() {
        return discount;
    }

}